# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=py3-inotify
_pkgname=pyinotify
pkgver=0.9.6
pkgrel=12
pkgdesc="Linux filesystem events monitoring"
options="!check" # No testsuite
url="https://pypi.org/project/pyinotify"
arch="all"
license="MIT"
makedepends="py3-setuptools python3-dev"
subpackages="$pkgname-pyc"
source="https://files.pythonhosted.org/packages/source/${_pkgname:0:1}/$_pkgname/$_pkgname-$pkgver.tar.gz
	riscv64-and-aarch64.patch
	force-c-ext.patch
	"
builddir="$srcdir"/$_pkgname-$pkgver

replaces="py-inotify" # Backwards compatibility
provides="py-inotify=$pkgver-r$pkgrel" # Backwards compatibility

build() {
	python3 setup.py build
}

package() {
	python3 setup.py install --skip-build --root="$pkgdir"
}

sha512sums="
b52de43293b06b32236e90b7c33fac061f3095cd7d4aecec89a099d56020db1a85440ab9dcc8b521238c001fc49a1f37d1b16d621bc1acab4d7273aebcaadbc5  pyinotify-0.9.6.tar.gz
83c2f30461b43736088b47cc528ca058cc8975367c48c89bead53a48f9d65b34f267085178d815960c88958f47c138a6f133479b8961f1f1ff51b15bc61d1378  riscv64-and-aarch64.patch
28fe821c7fd4edf5f359c2d6026bfe95477ed167ea6948b3785d3c1708513c0e038dd4d9f3988a26c02c43bfaac9acb0357ee7edd6d5b0b7ae6c40000e31c485  force-c-ext.patch
"
